<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8" />
    <title>module imgEdit</title>
    <link rel="stylesheet" href="../common/lib/semantic/semantic.min.css">
    <link rel="stylesheet" href="../common/css/base.css">
    <link rel="stylesheet" href="../common/css/header.css">
    <link rel="stylesheet" href="../common/css/left.css">
    <link rel="stylesheet" href="css/imgEdit.css">
</head>
<body>
<div id="header">
    <div class="view_item" v-on:click="iLeft" ><i class="pointing left icon"></i></div>
    <div class="left">
        <div class="item"><i class="home icon"></i>AccurMedicine</div>
    </div>
    <div class="center">
        <span class="text">APP内容管理发布工具</span>
    </div>
    <div class="right">
        <div class="item"><i class="user icon"></i>Admin</div>
        <div class="item"><i class="sign out icon"></i> </div>
    </div>
</div>
<div class="container">
    <div id="left">
        <left></left>
    </div>
    <div id="right">
        <div class="navigation">
            <div class="ui breadcrumb">
                <div class="section">首页</div>
                <i class="right angle icon divider"></i>
                <div class="section">栏目定义</div>
                <i class="right angle icon divider"></i>
                <div class="active section">图片轮播设置</div>
            </div>
        </div>
        <div class="module_imgEdit">
            <h1 class="ui horizontal divider">轮播图片信息</h1>
            <div class="ui form">
                <div class="three fields">
                    <module v-bind:module="params.module"></module>
                    <ymd v-bind:ymd="params.date"></ymd>
                    <div class="field">
                        <label>有效时间</label>
                        <select v-model="params.equal" class="ui fluid dropdown">
                            <option value="0">等于日期</option>
                            <option value="1">大于日期</option>
                            <option value="2">大于等于日期</option>
                        </select>
                    </div>
                </div>
                <div class="img_ground">
                    <div class="img_show">
                        <img v-bind:src="url(params.photos[count_1].photoUrl)" />
                        <div class="img_info">
                            <div>名称: {{params.photos[count_1].name}}</div>
                            <div>图片地址:{{params.photos[count_1].photoUrl}}</div>
                            <div>指向内容地址:{{params.photos[count_1].contentUrl}}</div>
                        </div>
                    </div>
                    <div class="img_thumb">
                        <div v-bind:class="{active: index == count_1}"
                             v-for="(index,item) in params.photos"  class="item" v-on:click="count_1 = index">
                            <img v-bind:src="url(item.photoUrl)" />
                            <span class="clear" v-if="item.photoUrl != ''" v-on:click="clear(index)"><i class="remove icon"></i></span>
                            <span class="select" v-on:click="select(index+1)" v-if="item.photoUrl == ''" >选择文件</span>
                            <span class="upload" v-if="item.photoUrl == ''" v-on:click="upload(index)"><i class="upload icon"></i>上传</span>
                            <span class="success" v-if="item.photoUrl != ''"><i class="checkmark  icon"></i></span>
                        </div>
                        <input type="file" v-on:change="change($event,1)" id="img_1" name="img_1" v-show="false"/>
                        <input type="file" v-on:change="change($event,2)" id="img_2" name="img_2" v-show="false"/>
                        <input type="file" v-on:change="change($event,3)" id="img_3" name="img_3" v-show="false"/>
                        <input type="file" v-on:change="change($event,4)" id="img_4" name="img_4" v-show="false"/>
                        <input type="file" v-on:change="change($event,5)" id="img_5" name="img_5" v-show="false"/>
                    </div>
                    <div class="img_select">
                        <div class="fields">
                            <div class="four wide field">
                                <label>图片组栏目</label>
                                <select v-model="img_select" class="ui fluid dropdown">
                                    <option value="img_1">图片一</option>
                                    <option value="img_2">图片二</option>
                                    <option value="img_3">图片三</option>
                                    <option value="img_4">图片四</option>
                                    <option value="img_5">图片五</option>
                                </select>
                            </div>
                            <div class="six wide field">
                                <label>名称</label>
                                <input v-model="params.photos[count_2].name" placeholder="请输入名称" />
                            </div>
                            <div class="six wide field">
                                <label>指向内容地址</label>
                                <input v-model="params.photos[count_2].contentUrl" placeholder="请输入内容地址" />
                            </div>
                        </div>
                    </div>
                </div>
                <div class="submit">
                    <span v-on:click="save">保存</span>
                </div>
            </div>
        </div>
    </div>
</div>
</body>
<script type="text/javascript" src="../common/lib/jquery.min.js"></script>
<script type="text/javascript" src="../common/lib/ajaxfileupload.js"></script>
<script type="text/javascript" src="../common/lib/vue.js"></script>
<script type="text/javascript" src="../common/js/header.js"></script>
<script type="text/javascript" src="../common/js/left.js"></script>
<script type="text/javascript" src="js/imgEdit.js"></script>
</html>